//
//  JudgeSetDJ.m
//  RTUApp
//
//  Created by 陈德军 on 2017/7/12.
//  Copyright © 2017年 陈德军. All rights reserved.
//

#import "JudgeSetDJ.h"

@implementation JudgeSetDJ
+ (BOOL)judgeIsTheIPAddress:(NSString *)str{
    NSArray *array = [str componentsSeparatedByString:@","]; //字符串按照【分隔成数组
    if (array.count!=4) {
        return NO;
    }else{
        for (NSString *str in array) {
            if ([str intValue]<=0 || [str intValue] > 255) {
                return NO;
            }
        }
    }
    return YES;
}
@end
